<?php

use Hyperf\Database\Schema\Schema;
use Hyperf\Database\Schema\Blueprint;
use Hyperf\Database\Migrations\Migration;

class CreateTaskStep extends Migration
{
    /**
     * Run the migrations.
     */
    public function up(): void
    {
        Schema::create('task_step', function (Blueprint $table) {
            $table->integerIncrements('id');
            $table->unsignedInteger('task_id')->default(0)->comment('任务id');
            $table->unsignedTinyInteger('step_type')->default(0)->comment('步骤类型：1步骤10，2步骤20-29，3步骤30');
            $table->string('text', 255)->default('')->comment('文本描述');
            $table->string('image', 255)->default('')->comment('图片');
            $table->timestamps();
        });
    }

    /**
     * Reverse the migrations.
     */
    public function down(): void
    {
        Schema::dropIfExists('task_step');
    }
}
